﻿
// ColorPicker, Copyright Mirosław M. Mączka.  All Rights Reserved. This code released under the terms of the Microsoft Public License (MS-PL, http://opensource.org/licenses/ms-pl.html.)

namespace ColorPicker
{
    public class ColorDefinitionPlus
    {
        public string Name { get; set; }
        public string X { get; set; }
        public byte ColorR { get; set; }
        public byte ColorG { get; set; }
        public byte ColorB { get; set; }
        public string CodeName { get; set; }
        //
        public ColorDefinitionPlus()
        {
        }
        public ColorDefinitionPlus(string Name, string X, byte ColorR, byte ColorG, byte ColorB, string CodeName)
        {
            this.Name = Name;
            this.X = X;
            this.ColorR = ColorR;
            this.ColorG = ColorG;
            this.ColorB = ColorB;
            //
            this.CodeName = CodeName;

        }
        public static bool IsSameColor(ColorDefinitionPlus a, ColorDefinitionPlus b)
        {
            return a.ColorR == b.ColorR && a.ColorG == b.ColorG && a.ColorB == b.ColorB;
        }
    }
}
